package JAVASE520;

public class gedou2 {
    public static void main(String[] argc){
        Role r1=new Role("乔峰",100,'男');
        Role r2=new Role("碧萝",120,'女');
        System.out.println("角色1："+r1.getName()+'\n'+"外貌："+r1.getFace()+'\n'+"血量："+r1.getBlood()+'\n'+"性别："+r1.getGender());
        System.out.println("角色2："+r2.getName()+'\n'+"外貌："+r2.getFace()+'\n'+"血量："+r2.getBlood()+'\n'+"性别："+r2.getGender());
        while(true){
            r1.attack(r2);
            if(r2.getBlood()==0){
                System.out.println(r1.getName()+"K.O了"+r2.getName());
                break;
            }
            r2.attack(r1);
            if(r1.getBlood()==0){
                System.out.println(r2.getName()+"K.O了"+r1.getName());
                break;
            }
        }

    }
}